//
//  ClassTryeCell.m
//  轮胎商城
//
//  Created by 张晋磊 on 2017/3/28.
//  Copyright © 2017年 张晋磊. All rights reserved.
//

#import "ClassTryeCell.h"

@implementation ClassTryeCell

-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{

    if(self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]){
    
        [self.contentView addSubview:self.img];
        [self.contentView addSubview:self.lab];
    }
    return self;
}

-(UILabel *)lab{

    if(!_lab){
    
        _lab = [[UILabel alloc]initWithFrame:CGRectMake(65, 0, 200, 20)];
        
        _lab.textColor = [UIColor blackColor];
        
        _lab.backgroundColor = [UIColor whiteColor];
    }
    return _lab;
}

-(UIImageView *)img{

    if(!_img){
    
        _img = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, 50, 50)];
        
        _img.contentMode = UIViewContentModeScaleAspectFill;
    }
    return _img;
}

@end
